<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
<script>
    const zzc = [
        {flight_mach_number: '0.12', flight_attack_angle: '0.000', 'flight_sideslip_angle': '1.000'}
    ]

    const data = [];

    zzc.forEach(row => {
        if (!data[row]) {
            data[row] = { workType: row, data: [] };
        }

        const existingItem = data[row].data.find(item => item.number === row.pneumaticValue);

        if (existingItem) {
            existingItem[row.pneumaticKey] = row.pneumaticValue;
        } else {
            const newItem = { [row.pneumaticKey]: row.pneumaticValue };
            data[row].data.push(newItem);
        }
    });

    console.log(data);
    const aaa = [
        {
            name: "飞行攻角",
            xData: [0.12, 0.12, 2, 12],
            yData: [2,3,4,5]
        },
        {
            name: "飞行侧滑角",
            xData: [0.8, 0.9, 1.2, 12],
            yData: [12, 13, 5, 5]
        }
    ]

</script>
</body>
</html>